package com.ctshk.rpc.tour.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ctshk.rpc.tour.base.CustomBaseMapper;
import com.ctshk.rpc.tour.entity.SeriesTripVisa;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 * 系列团团期签证 Mapper 接口
 * </p>
 *
 * @author 谢诗宏
 * @since 2021-01-29
 */
public interface SeriesTripVisaMapper extends CustomBaseMapper<SeriesTripVisa> {

    /**
     * 根据团期ID获取签证ID列表
     * @param id
     * @return
     */
    @Select("SELECT visa_id\n" +
            "FROM t_series_trip_visa\n" +
            "WHERE trip_id = #{trip_id} AND is_deleted = 0")
    List<Long> queryVisaIdList(@Param("trip_id") Long id);
}
